package lab02.Test03;

/**
 * Created by Administrator on 2017/10/12.
 */
public class Student {
    // 1.属性
    float computerScore;
    float mathScore;
    float englishScre;

    // 2.行为:求总分、平均分、最高分、最低分、并输出一个学生的完整信息；
    float sum(){
        return computerScore+mathScore+englishScre;
    }
    float average(){
        return (computerScore+mathScore+englishScre)/3;
    }
    float  max() {
       float max = computerScore > mathScore ? computerScore : mathScore;
       max=max>englishScre?max:englishScre;
       return max;
    }
        float min(){
        float min=computerScore<mathScore?computerScore:mathScore;
        return min;
    }
    void printSdudent(){
        System.out.println("计算机成绩："+computerScore);
        System.out.println("数学成绩："+mathScore);
        System.out.println("英语成绩："+englishScre);
    }

    public static void main(String[] args) {

    }
    // 3.构造函数
    // 4.main函数
}
